// @ts-ignore
/* eslint-disable */
import { request } from '@umijs/max';
const apiPrefix = '/web';

/** 分页查询告警列表 GET /event/data/historyList */
export async function eventDataControllerGetPageHistoryList(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.eventDataControllerGetPageHistoryListParams,
  options?: { [key: string]: any },
) {
  return request<API.Pagination>(`${apiPrefix}/event/data/historyList`, {
    method: 'GET',
    params: {
      ...params,
      req: undefined,
      ...params['req'],
      page: undefined,
      ...params['page'],
    },
    ...(options || {}),
  });
}

/** 获取事件分类层级关系 GET /event/data/level */
export async function eventDataControllerGetEventTypeLevel(options?: { [key: string]: any }) {
  return request<API.EventTypeLevel[]>(`${apiPrefix}/event/data/level`, {
    method: 'GET',
    ...(options || {}),
  });
}

/** 分页查询告警列表数据 GET /event/data/list */
export async function eventDataControllerGetPageEventList(
  // 叠加生成的Param类型 (非body参数swagger默认没有生成对象)
  params: API.eventDataControllerGetPageEventListParams,
  options?: { [key: string]: any },
) {
  return request<API.ApiResultPaginationEventMsg>(`${apiPrefix}/event/data/list`, {
    method: 'GET',
    params: {
      ...params,
    },
    ...(options || {}),
  });
}
